package com.byb.server.service.dto;


import java.time.ZonedDateTime;
import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;
import java.util.Objects;
import javax.persistence.Lob;

/**
 * A DTO for the ExpertOpinion entity.
 */
public class ExpertOpinionDTO implements Serializable {

    private Long id;

    private String expertHeaderImg;

    private String honor;

    private String expertName;

    @Lob
    private String expertComment;

    private String expertScore;

    private ZonedDateTime date;

    private Long productId;

    private String productProductName;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getExpertHeaderImg() {
        return expertHeaderImg;
    }

    public void setExpertHeaderImg(String expertHeaderImg) {
        this.expertHeaderImg = expertHeaderImg;
    }

    public String getHonor() {
        return honor;
    }

    public void setHonor(String honor) {
        this.honor = honor;
    }

    public String getExpertName() {
        return expertName;
    }

    public void setExpertName(String expertName) {
        this.expertName = expertName;
    }

    public String getExpertComment() {
        return expertComment;
    }

    public void setExpertComment(String expertComment) {
        this.expertComment = expertComment;
    }

    public String getExpertScore() {
        return expertScore;
    }

    public void setExpertScore(String expertScore) {
        this.expertScore = expertScore;
    }

    public ZonedDateTime getDate() {
        return date;
    }

    public void setDate(ZonedDateTime date) {
        this.date = date;
    }

    public Long getProductId() {
        return productId;
    }

    public void setProductId(Long productId) {
        this.productId = productId;
    }

    public String getProductProductName() {
        return productProductName;
    }

    public void setProductProductName(String productProductName) {
        this.productProductName = productProductName;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }

        ExpertOpinionDTO expertOpinionDTO = (ExpertOpinionDTO) o;
        if(expertOpinionDTO.getId() == null || getId() == null) {
            return false;
        }
        return Objects.equals(getId(), expertOpinionDTO.getId());
    }

    @Override
    public int hashCode() {
        return Objects.hashCode(getId());
    }

    @Override
    public String toString() {
        return "ExpertOpinionDTO{" +
            "id=" + getId() +
            ", expertHeaderImg='" + getExpertHeaderImg() + "'" +
            ", honor='" + getHonor() + "'" +
            ", expertName='" + getExpertName() + "'" +
            ", expertComment='" + getExpertComment() + "'" +
            ", expertScore='" + getExpertScore() + "'" +
            ", date='" + getDate() + "'" +
            "}";
    }
}
